package cn.runagain.demo.wechatminiappdemo.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * created by
 *
 * @author tuxianchao
 * @date 2018/6/11 下午5:52
 */
@Entity
@Table(name = "tbl_user_wechat_entry")
public class UserWechatEntry implements Serializable {
    @Id
    private Long userId;
    @Column(nullable = false)
    private String openid;
    @Column(nullable = false)
    private String sessionKey;

    public UserWechatEntry() {

    }

    public UserWechatEntry(Long userId, String openid, String sessionKey) {
        this.userId = userId;
        this.openid = openid;
        this.sessionKey = sessionKey;
    }

    public String getSessionKey() {
        return sessionKey;
    }

    public void setSessionKey(String sessionKey) {
        this.sessionKey = sessionKey;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }
}
